Optimal. Leaf size=131 \[ \frac{c 2^{-\frac{m}{2}+\frac{n}{2}+1} (a \sin (e+f x)+a)^m (c-c \sin (e+f x))^n (1-\sin (e+f x))^{\frac{m-n}{2}} (g \cos (e+f x))^{-m-n} \, _2F_1\left (\frac{m-n}{2},\frac{m-n}{2};\frac{1}{2} (m-n+2);\frac{1}{2} (\sin (e+f x)+1)\right )}{f g (m-n)} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.36937, antiderivative size = 131, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 45, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.089, Rules used = {2853, 2689, 70, 69} \[ \frac{c 2^{-\frac{m}{2}+\frac{n}{2}+1} (a \sin (e+f x)+a)^m (c-c \sin (e+f x))^n (1-\sin (e+f x))^{\frac{m-n}{2}} (g \cos (e+f x))^{-m-n} \, _2F_1\left (\frac{m-n}{2},\frac{m-n}{2};\frac{1}{2} (m-n+2);\frac{1}{2} (\sin (e+f x)+1)\right )}{f g (m-n)} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 2853
Rule 2689
Rule 70
Rule 69
Rubi steps
\begin{align*} \int (g \cos (e+f x))^{-1-m-n} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{1+n} \, dx &=\left ((g \cos (e+f x))^{-2 m} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^m\right ) \int (g \cos (e+f x))^{-1+m-n} (c-c \sin (e+f x))^{1-m+n} \, dx\\ &=\frac{\left (c^2 (g \cos (e+f x))^{-m-n} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{m+\frac{1}{2} (-m+n)} (c+c \sin (e+f x))^{\frac{1}{2} (-m+n)}\right ) \operatorname{Subst}\left (\int (c-c x)^{1-m+\frac{1}{2} (-2+m-n)+n} (c+c x)^{\frac{1}{2} (-2+m-n)} \, dx,x,\sin (e+f x)\right )}{f g}\\ &=\frac{\left (2^{-\frac{m}{2}+\frac{n}{2}} c^2 (g \cos (e+f x))^{-m-n} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^{\frac{m}{2}+\frac{n}{2}+\frac{1}{2} (-m+n)} \left (\frac{c-c \sin (e+f x)}{c}\right )^{\frac{m}{2}-\frac{n}{2}} (c+c \sin (e+f x))^{\frac{1}{2} (-m+n)}\right ) \operatorname{Subst}\left (\int \left (\frac{1}{2}-\frac{x}{2}\right )^{1-m+\frac{1}{2} (-2+m-n)+n} (c+c x)^{\frac{1}{2} (-2+m-n)} \, dx,x,\sin (e+f x)\right )}{f g}\\ &=\frac{2^{1-\frac{m}{2}+\frac{n}{2}} c (g \cos (e+f x))^{-m-n} \, _2F_1\left (\frac{m-n}{2},\frac{m-n}{2};\frac{1}{2} (2+m-n);\frac{1}{2} (1+\sin (e+f x))\right ) (1-\sin (e+f x))^{\frac{m-n}{2}} (a+a \sin (e+f x))^m (c-c \sin (e+f x))^n}{f g (m-n)}\\ \end{align*}
Mathematica [C] time = 25.637, size = 207, normalized size = 1.58 \[ \frac{i c (\sin (e+f x)-1) (a (\sin (e+f x)+1))^m (c-c \sin (e+f x))^n (g \cos (e+f x))^{-m-n} \left (\, _2F_1\left (1,-m+n+1;-m+n+2;-\frac{i \left (\tan \left (\frac{1}{2} (e+f x)\right )-1\right )}{\tan \left (\frac{1}{2} (e+f x)\right )+1}\right )-\, _2F_1\left (1,-m+n+1;-m+n+2;\frac{i \left (\tan \left (\frac{1}{2} (e+f x)\right )-1\right )}{\tan \left (\frac{1}{2} (e+f x)\right )+1}\right )\right )}{f g (m-n-1) \left (\cos \left (\frac{1}{2} (e+f x)\right )-\sin \left (\frac{1}{2} (e+f x)\right )\right ) \left (\sin \left (\frac{1}{2} (e+f x)\right )+\cos \left (\frac{1}{2} (e+f x)\right )\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F] time = 29.86, size = 0, normalized size = 0. \begin{align*} \int \left ( g\cos \left ( fx+e \right ) \right ) ^{-1-m-n} \left ( a+a\sin \left ( fx+e \right ) \right ) ^{m} \left ( c-c\sin \left ( fx+e \right ) \right ) ^{1+n}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \left (g \cos \left (f x + e\right )\right )^{-m - n - 1}{\left (a \sin \left (f x + e\right ) + a\right )}^{m}{\left (-c \sin \left (f x + e\right ) + c\right )}^{n + 1}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F] time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\left (g \cos \left (f x + e\right )\right )^{-m - n - 1}{\left (a \sin \left (f x + e\right ) + a\right )}^{m}{\left (-c \sin \left (f x + e\right ) + c\right )}^{n + 1}, x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \left (g \cos \left (f x + e\right )\right )^{-m - n - 1}{\left (a \sin \left (f x + e\right ) + a\right )}^{m}{\left (-c \sin \left (f x + e\right ) + c\right )}^{n + 1}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]